home *** CD-ROM | disk | FTP | other *** search
/ Celestin Apprentice 5 / Apprentice-Release5.iso / Information / CSMP Digest / volume 2 / csmp-v2-009.txt < prev    next >
Text File  |  1995-06-30  |  38KB  |  945 lines

  1. C.S.M.P. Digest             Fri, 05 Feb 93       Volume 2 : Issue 9
  2.  
  3. Today's Topics:
  4.  
  5.     TCL, CPanes of variant shapes?
  6.     how do you do automated GUI testing?
  7.     Curves in QuickDraw GX
  8.  
  9.  
  10.  
  11. The Comp.Sys.Mac.Programmer Digest is moderated by Michael A. Kelly.
  12.  
  13. The digest is a collection of article threads from the internet newsgroup
  14. comp.sys.mac.programmer.  It is designed for people who read c.s.m.p. semi-
  15. regularly and want an archive of the discussions.  If you don't know what a
  16. newsgroup is, you probably don't have access to it.  Ask your systems
  17. administrator(s) for details.  If you don't have access to news, there is
  18. no way that I know of for you to post articles to the group.
  19.  
  20. Each issue of the digest contains one or more sets of articles (called
  21. threads), with each set corresponding to a 'discussion' of a particular
  22. subject.  The articles are not edited; all articles included in this digest
  23. are in their original posted form (as received by our news server at
  24. cs.uoregon.edu).  Article threads are not added to the digest until the last
  25. article added to the thread is at least one month old (this is to ensure that
  26. the thread is dead before adding it to the digest).  Article threads that
  27. consist of only one message are generally not included in the digest.
  28.  
  29. The entire digest is available for anonymous ftp from ftp.cs.uoregon.edu
  30. [128.223.8.8] in the directory /pub/mac/csmp-digest.  Be sure to read the
  31. file /pub/mac/csmp-digest/README before downloading any files.  The most
  32. recent issues are available from sumex-aim.stanford.edu [36.44.0.6] in the
  33. directory /info-mac/digest/csmp.  If you don't have ftp capability, the sumex
  34. archive has a mail server; send a message with the text '$MACarch help' (no
  35. quotes) to LISTSERV@ricevm1.rice.edu for more information.
  36.  
  37. The digest is also available via email.  Just send a note saying that you
  38. want to be on the digest mailing list to mkelly@cs.uoregon.edu, and you will
  39. automatically receive each new issue as it is created.  Sorry, back issues
  40. are not available through the mailing list.
  41.  
  42. Send administrative mail to mkelly@cs.uoregon.edu.
  43.  
  44.  
  45. -------------------------------------------------------
  46.  
  47. From: urban@yoda.fsl.noaa.gov (Art Urban)
  48. Subject: TCL, CPanes of variant shapes?
  49. Organization: Forecast Systems Lab, NOAA, Boulder CO, USA
  50. Date: Sun, 3 Jan 1993 21:37:13 GMT
  51.  
  52. Well, the subject line almost states the question well enough...but,
  53.  
  54. Can I make a CPane subclass which is a *region* and not a rectangle?
  55.  
  56. I would love to have a hex shaped region for trapping GoodClicks and
  57. such, without having overlapping panes. I see problems handling overlapping
  58. rectangles which contain "drawn" hexes which must abutt each other.
  59.  
  60. - -- 
  61. Art Urban                             urban@yoda.fsl.noaa.gov
  62. ===============================================================================
  63.  "Look, he's being attacked by creamy nugget centers."              -Joel
  64. ===============================================================================
  65.  
  66. +++++++++++++++++++++++++++
  67.  
  68. From: jimlynch@netcom.com (Jim Lynch)
  69. Date: 4 Jan 93 23:01:14 GMT
  70. Organization: Netcom Online Communications Services (408-241-9760 login: guest)
  71.  
  72. Yes, you can. Here's mine. Feel free to have it as a toy, but if you
  73. distribute it, it must include this message. Don't use it in
  74. commercially available software without talking to me well in advance.
  75.  
  76. - --------------- *** file CRegion.c *** ------------------
  77. #include "CRegion.h"
  78.  
  79. void CRegion::IRegion
  80. (
  81.         CView                   *anEnclosure,
  82.         CBureaucrat             *aSupervisor,
  83.         short                   aWidth,
  84.         short                   aHeight,
  85.         short                   aHEncl,
  86.         short                   aVEncl,
  87.         SizingOption    aHSizing,
  88.         SizingOption    aVSizing
  89. )
  90. {
  91.         inherited::IPane
  92.         (
  93.                 anEnclosure, aSupervisor,
  94.                 aWidth, aHeight,
  95.                 aHEncl, aVEncl,
  96.                 aHSizing, aVSizing
  97.         ) ;
  98.  
  99.         itsRegionH = NewRgn() ;
  100. }
  101.  
  102. void CRegion::Dispose(void)
  103. }
  104.         return(result) ;
  105.         }
  106.                 result = PtInRgn(thePoint, itsRegionH) ;
  107.                 thePoint.v = theLPoint.v ;
  108.                 thePoint.h = theLPoint.h ;
  109.                 WindToFrame(thePoint, &theLPoint) ;
  110.         {
  111.                 aWidth, aHeight,
  112.                 aHEncl, aVEncl,
  113.                 aHSizing, aVSizing
  114.         ) ;
  115.  
  116.         itsRegionH = NewRgn() ;
  117. }
  118.  
  119. void CRegion::Dispose(void)
  120. {
  121.         DisposeRgn(itsRegionH) ;
  122.  
  123.         inherited::Dispose() ;
  124. }
  125.  
  126. Boolean CRegion::Contains(Point thePoint)
  127. {
  128.         LongPt theLPoint ;
  129.         Boolean result ;
  130.  
  131.         result = FALSE ;
  132.  
  133.         if(ReallyVisible())
  134.         {
  135.                 WindToFrame(thePoint, &theLPoint) ;
  136.                 thePoint.h = theLPoint.h ;
  137.                 thePoint.v = theLPoint.v ;
  138.                 result = PtInRgn(thePoint, itsRegionH) ;
  139.         }
  140.  
  141.         return(result) ;
  142. }
  143.  
  144. - -------------- *** end of CRegion.c *** ------------------
  145.  
  146. Here's the .h file:
  147.  
  148. - --------------- *** CRegion.h *** --------------------
  149. #pragma once
  150.  
  151. #include <CPane.h>
  152.  
  153. class CRegion : public CPane
  154. {
  155. protected:
  156.         RgnHandle itsRegionH ;
  157.  
  158. public:
  159.         void IRegion
  160.         (
  161.                 CView                   *anEnclosure,
  162.                 CBureaucrat             *aSupervisor,
  163.                 short                   aWidth,
  164.                 short                   aHeight,
  165.                 short                   aHEncl,
  166.                 short                   aVEncl,
  167.                 SizingOption    aHSizing,
  168.                 SizingOption    aVSizing
  169.         ) ;
  170.         void Dispose(void) ;
  171.  
  172.         Boolean Contains(Point thePoint);
  173. } ;
  174.  
  175. - ---------------- *** end of CRegion.h *** ------------
  176.  
  177. Notice I don't do anything to itsRegionH after allocating; that's up to your
  178. code. Also note that I override CPane::Contains() so CRegion's version checks
  179. to see if the point lies in the region referred to by itsRegionH.
  180.  
  181. I use this as an abstract class. I was doing something with piano keys which
  182. are irregular shapes. Made buttons out of them, as I recall... In any case,
  183. my CKey::IKey method called its superclass' IRegion method then did something
  184. to the region (like make a shape).
  185.  
  186. So you could make a CHex which is a subclass of CRegion and draw a hex polygon
  187. in itsRegionH...
  188.  
  189. ---------------------------
  190.  
  191. From: bagwill@swe.ncsl.nist.gov (Bob Bagwill)
  192. Subject: how do you do automated GUI testing?
  193. Date: 4 Jan 93 15:51:25 GMT
  194.  
  195. How does Apple (if they choose to respond) do automated testing
  196. of the GUI aspect of their product?
  197.  
  198. How do "professional" Mac developers do automated testing of
  199. their products?
  200.  
  201. I will summarize responses (if any).  If anyone is willing to
  202. share information with me, but don't want it shared with the
  203. net, put "PRIVATE" at the head of your response.
  204.  
  205. Warning: Don't send anything your lawyers don't want you to share.  And
  206. remember that Internet email is not secure.
  207.  
  208. - --
  209. Bob Bagwill
  210. bagwill@swe.ncsl.nist.gov
  211. NIST/Computer Systems Lab/Distributed Systems Engineering Group
  212.  
  213. +++++++++++++++++++++++++++
  214.  
  215. From: d88-jwa@dront.nada.kth.se (Jon Wtte)
  216. Date: 4 Jan 93 20:51:27 GMT
  217. Organization: Royal Institute of Technology, Stockholm, Sweden
  218.  
  219. In <7750@dove.nist.gov> bagwill@swe.ncsl.nist.gov (Bob Bagwill) writes:
  220.  
  221. >How does Apple (if they choose to respond) do automated testing
  222. >of the GUI aspect of their product?
  223.  
  224. >How do "professional" Mac developers do automated testing of
  225. >their products?
  226.  
  227. Apple has a very good product called Virtual User that lets
  228. you create customized or random sessions and play them back
  229. over a network to a lot of macs at the same time.
  230.  
  231. It's good, and I haven't seen anything better on any other
  232. platform. I seem to remember the arrangements about it being
  233. very inexpensive too.
  234.  
  235. >Warning: Don't send anything your lawyers don't want you to share.  And
  236. >remember that Internet email is not secure.
  237.  
  238. Huh? Why would anyone NOT remember that? It's a fact of
  239. life and has always been.
  240.  
  241. Now, phone lines (cellular phones especially) are not
  242. secure EITHER, and that's something people tend to forget.
  243.  
  244.  
  245. - -- 
  246.  -- Jon W{tte, h+@nada.kth.se, Mac Hacker Deluxe --
  247.  
  248.    Speed is arbitrary. Don't believe me? Try a PowerBook 180 running
  249.    System 7 against a 486 laptop running Windows 3.1.
  250.  
  251. +++++++++++++++++++++++++++
  252.  
  253. From: howard@netcom.com (Howard Berkey)
  254. Date: 4 Jan 93 22:29:55 GMT
  255. Organization: Netcom Online Communications Services (408-241-9760 login: guest)
  256.  
  257. In article <1993Jan4.205127.25229@kth.se> d88-jwa@dront.nada.kth.se (Jon Wtte) writes:
  258. >In <7750@dove.nist.gov> bagwill@swe.ncsl.nist.gov (Bob Bagwill) writes:
  259. >
  260. >>How does Apple (if they choose to respond) do automated testing
  261. >>of the GUI aspect of their product?
  262. >
  263. >>How do "professional" Mac developers do automated testing of
  264. >>their products?
  265. >
  266. >Apple has a very good product called Virtual User that lets
  267. >you create customized or random sessions and play them back
  268. >over a network to a lot of macs at the same time.
  269. >
  270. >It's good, and I haven't seen anything better on any other
  271. >platform. I seem to remember the arrangements about it being
  272. >very inexpensive too.
  273. >
  274.  
  275. You can say that again.  Similar tools for the PC are ~3-500 dollars,
  276. and x-based tools start around $3-15,000.  (They do more though.  Not an
  277. order of magnitude more, however.)  VU is supposedly a good package.
  278.  
  279. - -Howard
  280.  
  281. - -- 
  282. ::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::
  283. Howard "Pasty-faced" Berkey                              howard@netcom.com
  284.             I just don't want to know, anymore.
  285. ... .. ...   ... .. ...   ... .. ...    ... .. ...   ... .. ...   ... .. ...
  286.  
  287. ---------------------------
  288.  
  289. From: lari@strauss.cs.unc.edu (Humayun Lari)
  290. Subject: Curves in QuickDraw GX
  291. Date: 14 Dec 92 02:45:27 GMT
  292.  
  293.  
  294. Hi, all. Yes, I have finals starting tomorrow, but there's one little question
  295. I just *have* to ask... :-)
  296.  
  297. Fact: QuickDraw GX is going to use quadratic bezier curves a la TrueType.
  298.  
  299. However: editing quadratic curves is somewhat painful compared to editing
  300. PostScript cubic curves, because of the number of extra points required to
  301. describe similar contours.
  302.  
  303. So: are we going to see lots of GX programs that <ouch> make us use quadratic
  304. curves to describe shapes? Or <grin> is there some magic way to display cubic
  305. curves using quadratics? As far as I know, there's no simple way of doing so.
  306. Does <gasp> GX provide some way of performing this magic? If not <"display
  307. ignorance" mode on>, shouldn't it?
  308.  
  309. I guess what I'm worried about is programs showing up that make editing curves
  310. harder than it needs to be -- much like the spline curves in MacDraw...
  311.  
  312. Stressfully yours,
  313.  
  314. Humayun Lari
  315. (lari@cs.unc.edu)
  316.  
  317. P.S. Personally, I *still* think NuGraph sounds a little cooler than "QuickDraw
  318. GX"... of course, average users might think it was a charting package...
  319.  
  320. +++++++++++++++++++++++++++
  321.  
  322. From: bayes@hplvec.LVLD.HP.COM (Scott Bayes)
  323. Date: Thu, 17 Dec 1992 00:00:08 GMT
  324. Organization: Hewlett-Packard Co., Loveland, CO
  325.  
  326. > So: are we going to see lots of GX programs that <ouch> make us use quadratic
  327. > curves to describe shapes? Or <grin> is there some magic way to display cubic
  328. > curves using quadratics? As far as I know, there's no simple way of doing so.
  329. > Does <gasp> GX provide some way of performing this magic? If not <"display
  330. > ignorance" mode on>, shouldn't it?
  331.  
  332. Quadratics and (non-degenerate) cubics can't even describe the same
  333. curves.  It's hard to see how to do the "magic" without approximations
  334. and lotsa MIPS, as you say.
  335.  
  336. ScottB
  337.  
  338. +++++++++++++++++++++++++++
  339.  
  340. From: perm@csd.uu.se (Per Mildner)
  341. Date: 18 Dec 92 14:28:18
  342. Organization: Computing Science Dept.,Uppsala University, Sweden
  343.  
  344.  
  345. I seem to remember a question about this at the last WWDC. I think the
  346. specific question was about outlining cubic curves requiring quadratic
  347. curves, this was from someone who had implemented similar
  348. functionality in a product. The answer was something like: "Yes,
  349. normally, but we have some very bright math people", ie, they use some
  350. sort of approximation magic.
  351.  
  352. - --
  353. Per Mildner            perm@CSD.UU.SE
  354. Computing Science Dept.        tel: +46 18181049
  355. Uppsala University, Sweden    fax: +46 18521270
  356.  
  357. +++++++++++++++++++++++++++
  358.  
  359. From: bwilliam@iat.holonet.net (Bill Williams)
  360. Organization: HoloNet National Internet Access BBS: 510-704-1058/modem
  361. Date: Wed, 23 Dec 1992 06:12:38 GMT
  362.  
  363. >From the center of my handwritten notes regarding Quickdraw GX as presented
  364. at Apples May 92 WWDC....
  365.  
  366. "The spline routines are used with inset and an outset values to create 
  367. "fat" splines, the two outer edges are different splines (derivitive 
  368. curves) that approach cubic order complexity, but are not, and can be
  369.  converted back to the original very quickly (Rob Johnson, a math prof
  370.  from UCLA invented fast transformation algorithms for all QD GX spline
  371.  calculations, and is now an apple QD GX contributor)"
  372.  
  373.  
  374. For those interested heres a bunch of my other observations as recorded that
  375. week intact and without changes......
  376.  
  377.  
  378.  
  379. Beyond QuickDraw : the next generation in imaging
  380. Given by Cary Clark - graphics team leader and author of color fonts, and
  381. old 3D quickdraw.
  382.  
  383. The introduction of several discussions of Apples COMPLETE REPLACEMENT of
  384. QuickDraw with a near clone of Adobe DisplayPostscript called QuickDraw
  385. GX. Its code name was Skia ("Skee-ah"). It is a geometry (object) based
  386. graphics model.
  387.  
  388. It is nearly finished and will be available three different ways (end user
  389. $$, distributable license, and eventually free inclusion in a future
  390. system release).
  391.  
  392. Wow, wow, wow. It is definitely NOT as fast as display postscript, but in
  393. many ways it seemed faster. Work started in 1988 before DisplayPostscript
  394. was shown publicly. It is of course completely device independent, and its
  395. output files when printing, even after customization for a specific device
  396. at spool initiation ARE DEVICE INDEPENDENT AT ALL TIMES. Final printed
  397. output devices may be raster devices, vector devices (plotter) or
  398. Postscript devices.
  399.  
  400. No words or tokens are used in the imaging model, there is no server
  401. level, instead it appears as good-old-fashioned quickdraw to a normal
  402. programmer except that all geometries are based on 32 bit values and
  403. sometimes 64 bit values. (A fixed point is assumed when some values are used)
  404.  
  405. Unlike DisplayPostscript floating point values and computations are NOT
  406. used. This is a negative trait. 
  407.  
  408. Also unlike postscript, YOU MAY NOT SEND CODE OF ANYKIND TO THE OUTPUT
  409. SPOOLED IMAGE. Thus the author of "Jag" was told that his anti-aliasing
  410. product has no value because the effects of his product EXCEPT AS DEVICE
  411. DEPENDENT BITMAPS cannot be sent through the spooler and therefore should
  412. not be integrated into QD GX. The reason: THE GOAL OF QD GX IS TO MATCH
  413. THE SCREEN TO THE PRINTED OUTPUT. No code encapsulation is permitted. This
  414. is a good intention, but not providing spoolable code (as with PostScript)
  415. is a negative trait. 
  416.  
  417. Like DisplayPostscript, QD GX is a single pixel color model, and
  418. anti-aliasing and ramping is not supported. This is not to be confused
  419. with the pleasing types of blending fills that it does support.
  420.  
  421.  
  422. You may mix Quickdraw commands interspersed with QuickDraw GX without too
  423. much effort. Unfortunately, if you do, you must be careful to use a CASE
  424. SENSITIVE LANGUAGE such as Modula-2, C, C++ because there is a RPointS and
  425. a RpointS as well as QuickDraws RRectS and the new QuickDraw GXUs RrectS.
  426. Though on one slide I saw the word RrectangleS instead of rect, so I
  427. assume in Pascal they have a RgxPointS and a RrectangleS redefinition.
  428.  
  429. It does everything that display postscript does and a few extra things
  430. (such as placing pictures at joins of two lines).
  431.  
  432. It has the AMAZING benefit of using the highly optimizable quadratic
  433. spline for all curve and path operations. Though it cannot draw a circle.
  434. (I am not joking, strictly speaking, MANY of QuickDraw GX primitives are
  435. actually "libraries" outside of the lower lever QuickDraw GX.) I think
  436. drawcircle is a library routine. The spline routines are used with inset
  437. and an outset values to create "fat" splines, the two outer edges are
  438. different splines (derivitive curves) that approach cubic order
  439. complexity, but are not, and can be converted back to the original very
  440. quickly (Rob Johnson, a math prof from UCLA invented fast transformation
  441. algorithms for all QD GX spline calculations, and is now an apple QD GX
  442. contributor)
  443.  
  444. I got the feeling that "shapes", not paths or spline derived curves, were
  445. used for all of the very fast animated demos presented  (50 demos). I
  446. believe that "shapes" do NOT possess splines but rather are decomposed
  447. curves defined solely of small straight line segments. This is for speed
  448. speed speed. The programmer gets to define the segmentation parameters used.
  449.  
  450. Shapes are defined by fixed point, to prevent degradation after any series
  451. of permanent transformations.
  452.  
  453. The system supports a three-D transformation matrix with many library
  454. routines to help set the matrix parameters. Two values in the Matrix are
  455. unconventionally used for storage of variables meant for perspective
  456. distortion. (QD GX has no three dimensional routines, and the
  457. unconventional usage does not affect the non-existent "z" data)
  458. It has tons of layered transformation matrices at many layers before the
  459. final image is drawn and seems at most times to be a full blown 3D imaging
  460. model... but it isn't.
  461.  
  462. The matrix routines support fast skew, distort, and rotation (including
  463. bitmaps)
  464.  
  465. Patterns are now two parts, pattern data and "color shade" are separate
  466. identities.
  467.  
  468. There are still no pixel locations in QuickDraw, points have always been
  469. an abstraction and still are.... but programmers must be cautious to shift
  470. all position info to convert all points into fixed point math to avoid
  471. unwanted locations.
  472.  
  473. The new more accurate pixel locations allow much more exact vector line
  474. rotation even on 72 point monitors. The effect needs to be dynamic to
  475. discern the enhancement though.
  476.  
  477. It supports compressed "infinite-precision" BitMap regions, very nice
  478. results were obtained in the demos.
  479.  
  480. TrueType and Adobe type 1 fonts (under ATM) are EXACTLY EQUAL in usage in
  481. QD GX, neither has any preferential treatment in ANY WAY.
  482.  
  483. Font families have meaning now in the menu interface (like Adobe's Type
  484. Reunion already does)
  485.  
  486. The new font support is almost as complete as postscripts with some
  487. amazing differences. Primarily the ability to use different fancy fonts
  488. based on the characters adjacent to the font. Some astoundingly beautiful
  489. effects were shown with a slightly altered Zapf Chancery. Letters on the
  490. ends of words had bold sweeping flourishes, and capital letters at the
  491. beginning of words had long sweeping tails under the adjacent characters.
  492. WOW. Apple said they are commissioning a company to create a special "Old
  493. English" font for them.
  494.  
  495. A new Adobe Illustrator (version NIA 3.2) was shown that swapped back and
  496. forth between QD and QD GX. It had a GODDAMN STUPID PREVIEW MODE as it
  497. always has on systems that do not have built in display postscript,
  498. because of the nature of the program. The absolute horrifying restriction
  499. was only observed by me and other people that may have seen the
  500. "No-preview-mode-crap" NeXT version of Adobe Illustrator. Man, what an
  501. application not to show as a demo!
  502.  
  503. QD GX is a large set of different new technologies, especially for
  504. printing. A kinder gentler series of major changes in printer interfaces
  505. would make most people very happy. It is MUCH less cluttered, and far more
  506. restricted without probing. A control panel much like system 6's "general"
  507. is used to access third party extensions. In fact it is so simple a new
  508. menu item is defined by apple called "Print One Copy". Note the lack of
  509. "ellipses" (...). That's right it does what it says no questions asked.
  510. The audience clapped.
  511.  
  512. A printer "Finder" was created to manage spooling. It has as many features
  513. as the real finder in several ways. Plus it appears to be part of the
  514. Finder. WOW.
  515.  
  516. Plotters are supported.
  517.  
  518. Hit detection for mouse clicks as well as animated object collision is a
  519. major part of QD GX. Including accurate hit detection after all those
  520. layers of skewing, distorting, rotating, etcetera.... WOW. This is even
  521. better than the NeXT (one of the NeXT's few limitations from what I recall
  522. is a "lighter" hit detection system.
  523.  
  524. Multiple color spaces are supported (even within one image!!!!!!!!!)
  525.  
  526. It supports all the cool stuff color Postscript (2) does for dithering,
  527. screen rotation (arbitrary angles), etc. 
  528.  
  529. It supports viewports in a VERY ABSTRACT MANNER. a port can be a three-d
  530. is view any where in a space and can be displayed in a arbitrary shaped
  531. region anywhere on a device including MULTIPLE VIEWS OR THE SAME SCENE AT
  532. THE SAME TIME. The multiple views can all have different color depths and
  533. pixel resolutions, and dithering, and screening, and be somewhere on the
  534. same device!
  535.  
  536. Unlike postscript it supports RTL LTR and vertical languages, unlike
  537. Postscript it can be used to support indic and arabic languages where the
  538. characters change dramatically based on there position and neighboring
  539. glyphs. Arabic, Chinese and others where shown.
  540.  
  541. Like Postscript, the fonts can be filled, set on paths, stretched, etc.
  542. etc. etc. Including bizarre text effects as seen with many Postscript
  543. programs.
  544.  
  545. Users can specify weights directly in their applications (make it 10%
  546. bolder, etc.)!
  547.  
  548. Oliver Steele wrote some AMAZING high speed graphics demos that showcased
  549. QD GX and two of them,  "deflection angle" and "velocity lines" are
  550. definite collector items.
  551.  
  552. Like postscript, a path drawing a line cannot be truly "dashed". Like
  553. postscript the beginning and the ending of a path can have special
  554. endcaps. Endcaps are allowed to be "negative" (erasing)
  555.  
  556. QD GX supports multiple monitors. Apple acknowledged that Radius invented
  557. multiple monitor drawing first, not them or anyone else in the industry.
  558.  
  559. You cannot crash QDGX when its many many debugging options are enabled. 
  560.  
  561. QD GX uses ZERO BYTES OF APPLICATION HEAP and stores all its structures in
  562. its own very special heap structures. It uses almost no Macintosh
  563. routines. It does not ever use the memory manager. It cannot run out of
  564. memory if disk space is available.
  565.  
  566. Disk is used as memory FOR ANY AND ALL OPERATIONS! QDGX can work on
  567. immense bitmaps, far larger than supportable in RAM. Sadly, Cary Clark
  568. calls this "backing store" instead of "virtual memory" because he likes
  569. anal retentive 1967 IBM mainframe buzzwords.
  570.  
  571. QD GX has a special debugger, BUT THEY WERE NOT ALLOWED TO SHOW IT. Odd.
  572. very odd.
  573.  
  574. No recalculations are made in QD GX, it has lots of optimization
  575. strategies of all kinds (as does display postscript) but unlike its
  576. competitor, it can warn the user if wasteful code is being generated. Plus
  577. it never calculates any intermediate variable that is not eventually
  578. actually needed! If true I am impressed! It would be almost psychic-ware.
  579.  
  580. It runs (theoretically) in system 6, but needs 7.0 for printing of any kind.
  581.  
  582. The famous QD pattern scrolling bug (user preference?) is now selectable
  583. by programmer, patterns can be fixed or positional.
  584.  
  585. No assembly (very little) is used. Because they are greedy opportunistic
  586. pigs that are thinking of saving time porting it again and again
  587. naturally, but I feel that when 250,000 Motorola boxes from Apple ship per
  588. month they can afford to hire a few real programmers. GEEZ! Never in my
  589. life have I heard someone brag that almost none of their GRAPHICS ROUTINES
  590. are written in assembly.
  591.  
  592.  
  593. MAJOR LIMITATION: all views and bitmaps based on pixels can have more than
  594. 32K pixels per square side. EVER. But amazingly, QD GX will "butt-end"
  595. giant bitmaps through the system and accurately align and join them (even
  596. through translation, and distortion) so that you can extract and
  597. manipulate portions of them. In effect an INFINITE SIZED bitmap can be
  598. processed. (A satellite imaging company in the audience asked the question
  599. because all their photos have more than 32,000 pixels per side!)
  600.  
  601. Source code was handed out. An unprecedented amount of libraries and
  602. source code will be available before and after QD GX's debut.
  603.  
  604. ============================================================
  605.  
  606.  
  607. Whew! I have countless other pages of opinions and rambling drivel
  608. covering many other sessions at the WWDC written in the same manner if
  609. anyone is interested in my remarks on other Apple technologies.
  610.  
  611. Bill Williams (NOT familiar with QuickDraw GX yet)
  612.  
  613.  
  614.  
  615. +++++++++++++++++++++++++++
  616.  
  617. From: ldo@waikato.ac.nz (Lawrence D'Oliveiro, Waikato University)
  618. Date: 24 Dec 92 13:13:41 +1300
  619. Organization: University of Waikato, Hamilton, New Zealand
  620.  
  621. In article <Bzp7x4.90D@iat.holonet.net>, bwilliam@iat.holonet.net
  622. (Bill Williams) posts his thoroughly fascinating notes on QuickDraw GX.
  623. Thanks Bill! There's a place for your posting in my archive of USENET snippets.
  624.  
  625. > Wow, wow, wow. It is definitely NOT as fast as display postscript, but in
  626. > many ways it seemed faster.
  627.  
  628. That's a little worrying, considering the sort of hardware it seems to take
  629. to run Display PostScript (eg 68040-based NeXTs). Will QuickDraw GX not
  630. run on 68000 CPUs?
  631.  
  632. > No words or tokens are used in the imaging model,
  633.  
  634. Well, there'll be another lot of extensions to the QuickDraw picture format,
  635. won't there?
  636.  
  637. > there is no server level
  638.  
  639. No big loss. Having one X Window System is bad enough. :-)
  640.  
  641. > Like DisplayPostscript, QD GX is a single pixel color model, and
  642. > anti-aliasing and ramping is not supported.
  643.  
  644. You can use the existing anti-aliasing capabilities of Color QuickDraw,
  645. can't you?
  646.  
  647. > You may mix Quickdraw commands interspersed with QuickDraw GX without too
  648. > much effort. Unfortunately, if you do, you must be careful to use a CASE
  649. > SENSITIVE LANGUAGE such as Modula-2, C, C++ because there is a RPointS and
  650. > a RpointS as well as QuickDraws RRectS and the new QuickDraw GXUs RrectS.
  651. > Though on one slide I saw the word RrectangleS instead of rect, so I
  652. > assume in Pascal they have a RgxPointS and a RrectangleS redefinition.
  653.  
  654. Another option is to use a language with scope control, eg "OldQuickDraw.Point"
  655. versus "QuickDrawGX.Point". Modula-2 allows you to do this. But of course,
  656. language vendors will hack the interfaces to suit themselves. :-)
  657.  
  658. > Shapes are defined by fixed point, to prevent degradation after any series
  659. > of permanent transformations.
  660.  
  661. You'll get rounding errors, though. Does QuickDraw GX support "CORDIC"
  662. transformations? I think these are a representation of trig functions that
  663. allow you to do endlessly-repeated rotational transformations with zero rounding
  664. error.
  665.  
  666. > The new font support is almost as complete as postscripts with some
  667. > amazing differences. Primarily the ability to use different fancy fonts
  668. > based on the characters adjacent to the font. Some astoundingly beautiful
  669. > effects were shown with a slightly altered Zapf Chancery. Letters on the
  670. > ends of words had bold sweeping flourishes, and capital letters at the
  671. > beginning of words had long sweeping tails under the adjacent characters.
  672. > WOW. Apple said they are commissioning a company to create a special "Old
  673. > English" font for them.
  674.  
  675. Ah, the legendary "Line Layout Manager"! I saw a demo of this way back in
  676. 1988 (?), back when it was part of the promised feature set for System 7.
  677. The ligatures would appear and disappear as you were typing and deleting
  678. characters. I'm drooling just thinking about it...
  679.  
  680. > The famous QD pattern scrolling bug (user preference?) is now selectable
  681. > by programmer, patterns can be fixed or positional.
  682.  
  683. Is this the one where patterns are normally aligned to (0,0) in the coordinate
  684. space? You could always change that, it just wasn't very well explained how to
  685. do it. :-)
  686.  
  687. Lawrence D'Oliveiro                       fone: +64-7-856-2889
  688. Computer Services Dept                     fax: +64-7-838-4066
  689. University of Waikato            electric mail: ldo@waikato.ac.nz
  690. Hamilton, New Zealand    37^ 47' 26" S, 175^ 19' 7" E, GMT+13:00
  691. At first all I could do, in fact, was what I've been doing since the age of
  692. seven when any disaster has struck: ask myself how Batman would have acted
  693. in similar circumstances.                                -- PCW Oct '92
  694.  
  695. +++++++++++++++++++++++++++
  696.  
  697. From: d88-jwa@dront.nada.kth.se (Jon Wtte)
  698. Date: 24 Dec 92 23:47:52 GMT
  699. Organization: Royal Institute of Technology, Stockholm, Sweden
  700.  
  701. In <1992Dec24.131341.12976@waikato.ac.nz> ldo@waikato.ac.nz (Lawrence D'Oliveiro, Waikato University) writes:
  702.  
  703. >That's a little worrying, considering the sort of hardware it seems to take
  704. >to run Display PostScript (eg 68040-based NeXTs). Will QuickDraw GX not
  705. >run on 68000 CPUs?
  706.  
  707. The 68000 is dead, buried and forgotten. Except the PB100 is
  708. still the lightest PowerBook around. The screen on the Duos
  709. sucks whole mountains.
  710.  
  711. >> No words or tokens are used in the imaging model,
  712.  
  713. >Well, there'll be another lot of extensions to the QuickDraw picture format,
  714. >won't there?
  715.  
  716. QuickDraw GX is orthogonal from QuickDraw. It will co-exist, but
  717. QuickDraw will not be extended to know anything about GX. At
  718. least that's my impressino.
  719.  
  720. - -- 
  721.  -- Jon W{tte, h+@nada.kth.se, Mac Hacker Deluxe --
  722.  
  723.    There's no problem that can't be solved using brute-force algorithms
  724.    and a sufficiently fast computer. Ergo, buy more hardware.
  725.  
  726. +++++++++++++++++++++++++++
  727.  
  728. From: ksand@apple.com (Kent Sandvik )
  729. Date: 30 Dec 92 22:13:09 GMT
  730. Organization: (Evil Eye Creature from Mars, Inc.)
  731.  
  732. In article <Bzp7x4.90D@iat.holonet.net>, bwilliam@iat.holonet.net (Bill
  733. Williams) wrote:
  734. > No assembly (very little) is used. Because they are greedy opportunistic
  735. > pigs that are thinking of saving time porting it again and again
  736. > naturally, but I feel that when 250,000 Motorola boxes from Apple ship per
  737. > month they can afford to hire a few real programmers. GEEZ! Never in my
  738. > life have I heard someone brag that almost none of their GRAPHICS ROUTINES
  739. > are written in assembly.
  740.  
  741. Well, concerning a PowerPC port it makes sense, because asm is no-no
  742. or 'if-you-really-need-it' option on this platform.
  743.  
  744. Kent
  745. - -------------------
  746. Kent Sandvik (UUCP: ....!apple!ksand; INTERNET: ksand@apple.com)
  747. DISCLAIMER: Private activities on the Net.        
  748. "Don't just do something!  Stand there!"  -- Mystery Science Theater 3000
  749.  
  750. +++++++++++++++++++++++++++
  751.  
  752. From: russotto@eng.umd.edu (Matthew T. Russotto)
  753. Date: 31 Dec 92 22:49:23 GMT
  754. Organization: Project GLUE, University of Maryland, College Park
  755.  
  756. In article <ksand-301292141154@wintermute.apple.com> ksand@apple.com (Kent Sandvik ) writes:
  757. >
  758. >Well, concerning a PowerPC port it makes sense, because asm is no-no
  759. >or 'if-you-really-need-it' option on this platform.
  760.  
  761. Uhhh.... why?
  762.  
  763. - -- 
  764. Matthew T. Russotto    russotto@eng.umd.edu    russotto@wam.umd.edu
  765. Some news readers expect "Disclaimer:" here.
  766. Just say NO to police searches and seizures.  Make them use force.
  767. (not responsible for bodily harm resulting from following above advice)
  768.  
  769. +++++++++++++++++++++++++++
  770.  
  771. From: k044477@hobbes.kzoo.edu (Jamie R. McCarthy)
  772. Date: 1 Jan 93 01:26:08 GMT
  773. Organization: Kalamazoo College
  774.  
  775. russotto@eng.umd.edu (Matthew T. Russotto) writes:
  776. >ksand@apple.com (Kent Sandvik ) writes:
  777. >>
  778. >>[Why is QuickDraw GX written entirely in C?]
  779. >>Well, concerning a PowerPC port it makes sense, because asm is no-no
  780. >>or 'if-you-really-need-it' option on this platform.
  781. >
  782. >Uhhh.... why?
  783.  
  784. Because the PowerPC will run on a different processor, and the Toolbox
  785. will be written in the native code for that processor.  If Apple writes
  786. it in assembly, they have to write it (and debug it) twice.
  787. - -- 
  788.  Jamie McCarthy      Internet: k044477@kzoo.edu      AppleLink: j.mccarthy
  789.  "A degree in Computer Science from Berkeley didn't much qualify me to uphold
  790.   the banner of Chaos against the forces of Order."              - R. Zelazny
  791.  
  792. +++++++++++++++++++++++++++
  793.  
  794. From: werner@dewey.soe.berkeley.edu (John Werner)
  795. Date: 1 Jan 93 01:55:32 GMT
  796. Organization: School of Education, U.C. Berkeley
  797.  
  798. In article <1993Jan1.012608.5403@hobbes.kzoo.edu> k044477@hobbes.kzoo.edu (Jamie R. McCarthy) writes:
  799. >Because the PowerPC will run on a different processor, and the Toolbox
  800. >will be written in the native code for that processor.  If Apple writes
  801. >it in assembly, they have to write it (and debug it) twice.
  802.  
  803. Also, hand-coding something in assembler for a RISC chip is MUCH
  804. harder than on a traditional processor.  There's a smaller instruction
  805. set, more registers, and you have to worry about pipelining.  A good
  806. optimizing compiler can usually do a better job than most humans can
  807. do (at least in a reasonable amount of time).
  808. - -- 
  809. John Werner                        werner@soe.berkeley.edu
  810. UC Berkeley School of Education    
  811.  
  812. +++++++++++++++++++++++++++
  813.  
  814. From: sunilg@access.digex.com (Sunil Gupta)
  815. Date: 1 Jan 93 17:26:14 GMT
  816. Organization: Express Access Online Communications, Greenbelt, MD USA
  817.  
  818. werner@dewey.soe.berkeley.edu (John Werner) writes:
  819. : Also, hand-coding something in assembler for a RISC chip is MUCH
  820. : harder than on a traditional processor.  There's a smaller instruction
  821. : set, more registers, and you have to worry about pipelining.  A good
  822. : optimizing compiler can usually do a better job than most humans can
  823. : do (at least in a reasonable amount of time).
  824.  
  825. Your comment is true for RISC processors, but the complaint was being
  826. made about the CISC implementation. My small (4 person) programming shop
  827. maintains our code for a number of platforms. For CISC implementations
  828. we usually tune critical sections in assembly and usually let the
  829. compiler worry about that for RISC implementations. If we can do that,
  830. I'm sure that a megabucks company can spare a few programmers for a
  831. project that would greatly enhance their products.
  832.  
  833. Sunil Gupta
  834. Monsoon Software, Inc.
  835. sg@monsoon.com
  836.  
  837. +++++++++++++++++++++++++++
  838.  
  839. From: jmunkki@vipunen.hut.fi (Juri Munkki)
  840. Date: 1 Jan 93 18:34:51 GMT
  841. Organization: Helsinki University of Technology
  842.  
  843. In article <1i1urmINNt8g@mirror.digex.com> sunilg@access.digex.com (Sunil Gupta) writes:
  844. >werner@dewey.soe.berkeley.edu (John Werner) writes:
  845. >: Also, hand-coding something in assembler for a RISC chip is MUCH
  846. >: harder than on a traditional processor.  There's a smaller instruction
  847. >: set, more registers, and you have to worry about pipelining.  A good
  848. >: optimizing compiler can usually do a better job than most humans can
  849. >: do (at least in a reasonable amount of time).
  850. >
  851. >Your comment is true for RISC processors, but the complaint was being
  852. >made about the CISC implementation. My small (4 person) programming shop
  853. >maintains our code for a number of platforms. For CISC implementations
  854. >we usually tune critical sections in assembly and usually let the
  855. >compiler worry about that for RISC implementations. If we can do that,
  856. >I'm sure that a megabucks company can spare a few programmers for a
  857. >project that would greatly enhance their products.
  858.  
  859. I agree totally. In addition for QD GX, they used fixed point math. No
  860. current languages have built-in support for fixed point math, so a high
  861. level implementation will not benefit fully from the integer speed of
  862. fixed point.
  863.  
  864. Floating point is more suitable for high level languages and is probably
  865. just as fast as fixed point on the PowerPC architecture.
  866.  
  867. Then again, floating point would have been a very bad idea on the 68K
  868. machines.
  869.  
  870. It seems to me that the best solution would have been to write two versions:
  871. first a floating point/high level language implementation to debug the
  872. algorithms and then a fixed point/assembly language implementation to
  873. make it run ok on the current Macs.
  874.  
  875. - -- 
  876.   Juri Munkki                           Windsurf: fast sailing
  877.  jmunkki@hut.fi                          Macintosh: fast software
  878.  
  879. +++++++++++++++++++++++++++
  880.  
  881. From: d88-jwa@dront.nada.kth.se (Jon Wtte)
  882. Date: 4 Jan 93 11:26:10 GMT
  883. Organization: Royal Institute of Technology, Stockholm, Sweden
  884.  
  885. In <1992Dec31.224923.15838@eng.umd.edu> russotto@eng.umd.edu (Matthew T. Russotto) writes:
  886.  
  887. >>Well, concerning a PowerPC port it makes sense, because asm is no-no
  888. >>or 'if-you-really-need-it' option on this platform.
  889.  
  890. >Uhhh.... why?
  891.  
  892. Because you don't know how the compiler will schedule instructions
  893. and use condition code sets. Note the s. Computers today are not
  894. what they used to be; what we see now is a more and more complex
  895. interaction between compiler, libraries and hardware; you really
  896. need machines to keep track of getting it all right!
  897.  
  898. If you would want to write a context-free assembly portion, you
  899. would have to surround it by several (5 on each side?) NOP
  900. instructions; and then would degrade the performance of that
  901. asm{} by quite a bit...
  902.  
  903. Cheers,
  904.  
  905.                         / h+
  906.  
  907. - -- 
  908.  -- Jon W{tte, h+@nada.kth.se, Mac Hacker Deluxe --
  909.  
  910.  -- I don't fear death, it's dying that scares me.
  911.  
  912. +++++++++++++++++++++++++++
  913.  
  914. From: bhanafee@picasso.ads.com (Brian Hanafee)
  915. Date: 4 Jan 93 22:44:31 GMT
  916. Organization: Advanced Decision Systems, Mountain View, CA 94043, +1 (415)
  917.  
  918.  
  919. In article <1993Jan1.183451.22522@nntp.hut.fi> jmunkki@vipunen.hut.fi (Juri Munkki) writes:
  920. >I agree totally. In addition for QD GX, they used fixed point math. No
  921. >current languages have built-in support for fixed point math, so a high
  922.  ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  923.  
  924. *Almost* no current languages.  Ada does (see section 3.5.9 of the Ada
  925. LRM).  Though I still wouldn't recommend using Ada to write QD GX,
  926. it's a feature that of Ada that I'd really like to see in some other
  927. languages.  Note that this is in addition to, not in place of, integer
  928. and floating types.  When fixed point types are the right thing, it's
  929. much easier than using integers and trying to keep track of the binary
  930. point yourself.  Let the compiler do all the work!
  931.  
  932. >level implementation will not benefit fully from the integer speed of
  933. >fixed point.
  934.  
  935. - --
  936. Brian Hanafee                         Advanced Decision Systems
  937. bhanafee@ads.com                      1500 Plymouth Street
  938. (415) 960-7300                        Mountain View, CA 94043-1230
  939.  
  940. ---------------------------
  941.  
  942. End of C.S.M.P. Digest
  943. **********************
  944.